import 'package:flutter_bilibili/http/core/hi_net_adapter.dart';
import 'package:flutter_bilibili/http/request/base_request.dart';

// 测试数据，Mock数据
class MockAdapter extends HiNetAdapter{
  @override
  Future<HiNetResponse<T>> send<T>(BaseRequest request) {
    return Future<HiNetResponse<T>>.delayed(Duration(milliseconds: 1000), (){
      return HiNetResponse(
        data: {"code": 0, "message": "success"} as T,
        request: request,
        statusCode:403,
        statusMessage: "我是Mock 403数据"
      );
    }); // 延时1000毫秒
  }
}